package br.com.maps.contacts;

import java.util.List;

import android.content.ContentUris;
import android.net.Uri;
import android.provider.BaseColumns;
import android.widget.ImageView;

public class Contact {

	public static final String AUTHORITY = "br.com.maps.provider.contact";

	private long id = 0;

	private String nome;

	private ImageView photo;

	private String mapsEmail;

	private boolean isFavorite = false;

	private List<ExtensionLine> extensionLines;

	public String getName() {
		return this.nome;
	}

	public void setName(String name) {
		this.nome = name;
	}

	public ImageView getPhoto() {
		return this.photo;
	}

	public String getMapsEmail() {
		return this.mapsEmail;
	}

	public List<ExtensionLine> getRamais() {
		return this.extensionLines;
	}

	public void setPhoto(ImageView photo) {
		this.photo = photo;
	}

	public void setMapsEmail(String mapsEmail) {
		this.mapsEmail = mapsEmail;
	}

	public void setExtensionLines(List<ExtensionLine> extensionLine) {
		this.extensionLines = extensionLine;
	}

	public long getId() {
		return this.id;
	}

	public void setId(long id) {
		this.id = id;
	}

	public boolean isFavorite() {
		return this.isFavorite;
	}

	public void setFavorite(boolean isFavorite) {
		this.isFavorite = isFavorite;
	}

	public static final class ContactsColumns implements BaseColumns {
		private ContactsColumns() {
		}

		public static final Uri CONTENT_URI = Uri.parse("content://" + AUTHORITY + "/contacts");

		public static final String CONTENT_TYPE = "vnd.android.cursor.dir/vnd.google.contacts";

		public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/vnd.google.contacts";

		public static final String DEFAULT_SORT_ORDER = "_id ASC";

		public static final String NOME = "nome";

		public static final String EMAIL = "email";

		public static final String FAVORITO = "favorito";

		public static Uri getUriId(long id) {
			return ContentUris.withAppendedId(ContactsColumns.CONTENT_URI, id);
		}
	}

}
